package design.pattern.观察者模式;

public class MainClass {
    public static void main(String[] args) {
        Subject<String> subject = new ConcreateSubject();

        Obeserver<String> obeserver1 = new ConcreateObeserver("张三");
        Obeserver<String> obeserver2 = new ConcreateObeserver("李四");

        subject.attach(obeserver1);
        subject.attach(obeserver2);

        subject.change("123123");

    }
}

